﻿<UserControl x:Class="Kokomo.PeInspector.Reflection.CodeMetricsView"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" 
             d:DesignHeight="300" d:DesignWidth="300">
    <Grid>
		<FrameworkElement.Resources>
			<CollectionViewSource
								x:Key="MetricView"
								Source="{Binding CodeMetricViewModels}"
								>
				<!--<CollectionViewSource.GroupDescriptions>
									<PropertyGroupDescription PropertyName="Category"/>
								</CollectionViewSource.GroupDescriptions>-->
			</CollectionViewSource>
		</FrameworkElement.Resources>
		<ListView
							ItemsSource="{Binding CodeMetricViewModels}"
							TextSearch.TextPath="Label"
							>
			<ListView.View>
				<GridView>
					<GridViewColumn Header="Metric" DisplayMemberBinding="{Binding Label}" Width="100"/>
					<GridViewColumn Header="Value" DisplayMemberBinding="{Binding Text}" Width="400"/>
				</GridView>
			</ListView.View>
			<!--<ListView.GroupStyle>
								<GroupStyle>
									<GroupStyle.ContainerStyle>
										<Style TargetType="{x:Type GroupItem}">
											<Setter Property="Template">
												<Setter.Value>
													<ControlTemplate TargetType="{x:Type GroupItem}">
														<Expander>
															<Expander.Header>
																<TextBlock Text="{Binding Name}"/>
															</Expander.Header>
															<Expander.Content>
																<ItemsPresenter/>
															</Expander.Content>
														</Expander>
													</ControlTemplate>
												</Setter.Value>
											</Setter>
										</Style>
									</GroupStyle.ContainerStyle>
								</GroupStyle>
							</ListView.GroupStyle>-->
		</ListView>
	</Grid>
</UserControl>
